package com.project.server.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.poetry.common.entity.common.R;
import com.poetry.common.entity.po.User;
import com.project.server.mapper.TestMapper;
import com.project.server.service.ITestService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class TestServiceImpl extends ServiceImpl<TestMapper, User> implements ITestService {

    @Resource
    private TestMapper testMapper;

    @Override
    public R<String> test() {
        String name = "张三";
        QueryWrapper<User> wrapper = new QueryWrapper<>();
        wrapper.like("name", name);
        List<User> res = testMapper.selectList(wrapper);
        User user = new User();
        user.setUName("112");
        baseMapper.insert(user);
        throw null;
    }
}
